import {UI_CACHE_DB_DICT_DATA } from "@/store/mutation-types";
import Vue from "vue";

//从缓存中获取字典配置
export function getDictItemsFromCache(dictCode) {
    if (Vue.ls.get(UI_CACHE_DB_DICT_DATA) && Vue.ls.get(UI_CACHE_DB_DICT_DATA)[dictCode]) {
      let dictItems = Vue.ls.get(UI_CACHE_DB_DICT_DATA)[dictCode];
      return dictItems;
    }
}

// 请求接口获取字典数据
export function getDictItems() {
    return new Promise((resolve)=>{
        let data = {};
        resolve(data);
    })
}